<!--<?php
print <<<EOT
-->

<script src="../css/edit.js"></script>
<script>
<!--

function validate(form) {
	if(form.name.value.length < 2 || form.name.value.length > 32) {
		showMsg('msg_area', 'Name must be no more than 32 characters.');
		form.name.focus();
		return false;
	}
    
	if(form.retype_pwd.value == "") {
		showMsg('msg_area', 'Please enter password.');
		form.retype_pwd.focus();
		return false;
	}
	
	if(form.retype_pwd.value != form.pwd.value) {
		showMsg('msg_area', 'The passwords you entered did not match.');
		form.pwd.focus();
		return false;
	}
	
	if (!isEmail(form.email.value)) {
	    showMsg('msg_area', 'Invalid Email.');
		form.email.focus();
		return false;
	}

	return true;
}

//-->
</script>

<!--Content Start-->
<table width="95%" border="0" align="center">
  <tr> 
    <td>&nbsp;</td>
  </tr>
  <tr> 
    <td>
    
      <form action="user_add.php" method="post" name="form1" onSubmit="return validate(this)">
      <table width="60%" align="left">
    
      <tr><td><span id="msg_area" class="js_msg">$alert_message</span>
      
      <table width="95%" border="0" align="center">
        <tr> 
          <td align="right">&nbsp; </td>
        </tr>
        <tr> 
          <td>
            <table border="0" cellspacing="0" cellpadding="2">
              <tr> 
                <td>&nbsp;</td>
                <td>&nbsp;</td>
              </tr>
              <tr> 
                <td>Name :</td>
                <td>
                  <input type="text" class="text" name="name" value="$name">	  
                  <input name="action" type="hidden" value="add">
                </td>
              </tr>
              
              <!--tr> 
                <td>True Name :</td>
                <td>
                  <input type="text" class="text" name="truename" value="$truename">	  
                </td>
              </tr-->
              
              <tr> 
                <td>Password :</td>
                <td>
                  <input type="password" class="text" name="pwd" value="">	  
                </td>
              </tr>
              
              <tr> 
                <td> Retype Password :</td>
                <td>
                  <input type="password" class="text" name="retype_pwd" value="">	  
                </td>
              </tr>
              
              <tr> 
                <td>Email :</td>
                <td>
                  <input type="text" class="text" name="email" value="$email" size=30>	  
                </td>
              </tr>
              
              <tr> 
                <td>Phone :</td>
                <td>
                  <input type="text" class="text" name="phone" value="$phone" size=30>	  
                </td>
              </tr>
              
              <tr> 
                <td>Fax :</td>
                <td>
                  <input type="text" class="text" name="fax" value="$fax" size=30>	  
                </td>
              </tr>
                          
              <tr> 
                <td>&nbsp;</td>
                <td>&nbsp;</td>
              </tr>
            </table>
          </td>
        </tr>
      </table>
     </td></tr>
    
      <tr><td>
      <table width="95%" border="0" align="left">
        <tr> 
          <td align="center">
            <input type="image" src="../images/admin/bt_cancel.gif" width="78" height="23" onclick="location.href='user.php'; return false;"> 
            <input type="image" src="../images/admin/bt_save.gif" width="76" height="22" onclick="form1.submit"> 
          </td>
        </tr>
      </table>
      </td></tr>
      </table>
      </form>

      <p>&nbsp;</p></td>
  </tr>
</table>
<!--Content End-->

<!--
EOT;
?>-->